package com.max.xihu.patterns.proxy.common;

/**
 * @Author: Max
 * @Date: 2020-09-10 22:49
 * @Description:
 */
public class CoderProxy implements IUser{

    private IUser coder;

    public CoderProxy(IUser user){
        this.coder = user;
    }

    @Override
    public void eat() {
        this.coder.eat();
    }

    @Override
    public void work() {
        this.coder.work();
    }

    @Override
    public void sleep() {
        this.coder.sleep();
    }

    @Override
    public IUser getProxy() {
        return this;
    }
}
